﻿#ifndef QMLENGINE_H
#define QMLENGINE_H
/*
 *
 * QML注册类
 *
*/
#include <QObject>
#include <QQmlApplicationEngine>
#include <QQmlContext>


#include "cpptranslation.h"

#include "connectmanager.h"

#include "netprocess.h"

#include "LG_Choose/lg_choosedatamanager.h"

#include "PL_Process/pl_processdatamanager.h"

#include "QR_Process/qr_processdatamanager.h"

class QmlEngine : public QQmlApplicationEngine
{
    Q_OBJECT
public:
    QmlEngine(QObject *parent = nullptr);

    // 注册到QML
    void registerType();

    // 初始化 料高选择数据库
    void init_LG_DataBase();

    // 初始化 排料加工数据库
    void init_PL_DataBase();

    // 初始化 二维码料单数据库
    void init_QR_DataBase();

signals:

public slots:    

private:

    // 翻译类
    CppTranslation* m_CppTranslation = CppTranslation::getInstance(this);

    // 连接类
    ConnectManager* m_Connect = new ConnectManager(this);

    // 料高选择数据库类
    LG_ChooseDataManager* m_LG_Manager = new LG_ChooseDataManager(this);

    // 排料加工数据库类
    PL_ProcessDataManager* m_PL_Process = new PL_ProcessDataManager(this);

    // 二维码料单数据库类
    QR_ProcessDataManager* m_QR_Process = new QR_ProcessDataManager(this);

    NetProcess* m_NetWork_Process = new NetProcess(this);

};

#endif // QMLENGINE_H
